package org.czkt.service.impl;

import org.czkt.mapper.AppInfoMapper;
import org.czkt.pojo.AppInfo;
import org.czkt.pojo.vo.AppInfoVo;
import org.czkt.pojo.vo.AppQuery;
import org.czkt.service.AppInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;


@Service
public class AppInfoServiceImpl implements AppInfoService {

    @Autowired
    AppInfoMapper appInfoMapper;
    @Override
    public List<AppInfoVo> getList(AppQuery query, int pageIndex, int pageSize) {
        return appInfoMapper.getList(query,(pageIndex-1)*pageSize,pageSize);
    }

    @Override
    public int getCount(AppQuery query) {
        return appInfoMapper.getCount(query);
    }

    @Override
    public AppInfoVo getAppInfoById(Long id) {
        return appInfoMapper.getAppInfoById(id);
    }

    @Override
    public int updateAppInfo(Long id, Long status) {
        return appInfoMapper.updateAppInfo(id, status);
    }
}
